package com.masterclient.app.modules.goods.contract;

import android.support.annotation.NonNull;

import com.eoner.baselibrary.base.BasePresenter;
import com.eoner.baselibrary.base.BaseView;
import com.eoner.baselibrary.bean.goods.GoodDetailBean;
import com.eoner.baselibrary.bean.goods.GoodsCommentBean;
import com.eoner.baselibrary.bean.goods.ProductTeamBean;
import com.eoner.baselibrary.bean.goods.ProductTeamViewBean;
import com.masterclient.app.modules.order.beans.ConfirmCartBean;

import java.util.Map;

/**
 * 作者：sean
 * 创建时间：2017/6/29 08:54
 * 功能说明：
 */

public interface GoodsDetailContract {

    interface View extends BaseView {

        public void showGoodDetail(GoodDetailBean.DataBean dataBean);
        public void showCollectSuccess();
        public void showRemoveCollectSuccess();
        void addCartSuccess();
        void buyRightNowSuccess(String msg);
        void confirmCartSuccess(ConfirmCartBean.DataBean dataBean);

        void showGoodsComment(GoodsCommentBean.DataBean dataBean);
        void showMsg(String msg);
        void addFavoriteSuccess(String type);
        void addFavoriteFailed();
        void addShareSuccess();
        void showTeamList(ProductTeamBean.DataBean dataBean);
        void showTeamFailed();
        void showProductViewBean(ProductTeamViewBean.DataBean dataBean);
        void showProductViewBeanFail();
        void pickUpSalesruleSuccess(String coupon_code, String toast, Map<String,String> map);
    }


    abstract static class Presenter extends BasePresenter<View> {
        @Override
        public void onStart() {
        }

        public abstract void getGoodsDetail(@NonNull String id);
        public abstract void addFavorite(@NonNull String customer_id,@NonNull String id,@NonNull String type);
        public abstract void removeFavorite(@NonNull String customer_id,@NonNull String id,@NonNull String type);
        public abstract void addToCart(@NonNull String customer_id,@NonNull String product_id,@NonNull String qty);

        public abstract void buyRightNow(String address_id,String product_id,String buy_num,String is_group_buy,String is_original_price,String team_id);

        public abstract void getCommentList(String is_image,String page,String page_size,String product_id);

        public abstract void addFavorite(String product_id);
        public abstract void addShareInfo(String product_id);
        public abstract void productTeam(String id,String page,String page_size);

        public abstract void productTeamView(String id);
        public abstract void pickUpSalesrule(String coupon_code);


    }
}